#include "ray.h"

ray::ray()
{
}

ray::ray(point ori, vector3 dir)
{
	origin = ori;
	direction = dir;
	direction.normalize();
	distance = 0.0;
	insideObject = false;
}
ray::ray(point ori, point dest)
{
	origin = ori;
	direction = vector3(ori, dest);
	direction.normalize();
	destination = dest;
	insideObject = false;

	distance = 0.0;
}
ray::ray(point ori,vector3 dir, bool inside)
{
	origin = ori;
	direction = dir;
	direction.normalize();
	distance = 0.0;
	insideObject = inside;
}
ray::ray(photon p)
{
	origin = p.getPosition();
	direction = p.getDirection();
	insideObject = p.isinside();

	distance = 0.0;
}
ray::~ray(){}